<extend name="Public/base" />
<block name="body">
    <div class="main-title" style="padding-bottom: 10px;">
        <h2> <span style='color: red;'>{$shopId|get_sp_shop_name}</span> 它店申请调货单明细</h2>
        <br/>
    </div>
    <div><h3> 当前状态：<span style="color: red;">{:$transferStatus==0?"未审核":($transferStatus==10?"已审核，请至店管家发货":($transferStatus==20?"拒绝":($transferStatus==40?"已发货":($transferStatus==50?"已签收":"未定义"))))}</span></h3></div>
    <!-- 数据列表 -->
    <div class="data-table table-striped">
        <table>
            <thead>
            <tr>
                <th class="row-selected row-selected"><input class="check-all" type="checkbox"/></th>
                <th>商品名称</th>
                <th>数量</th>
                <th>单位</th>
                <th>配货价</th>
                <th>小计</th>
                <th></th>
            </tr>
            </thead>
            <tbody>
            <notempty name="_list">
                <volist name="_list" id="vo">
                    <tr>
                        <td><input class="ids" type="checkbox" name="id[]" value="{$vo.id}" /></td>
                        <td>{$vo.name}</td>
                        <td>{$vo.count}</td>
                        <td>{$vo.unit}</td>
                        <td>{$vo.transferStockPrice}</td>
                        <td>{$vo.subTotal}</td>
                        <td>
                        </td>
                    </tr>
                </volist>
                <else/>
                <td colspan="7" class="text-center"> aOh! 暂时还没有内容! </td>
            </notempty>
            </tbody>
        </table>
        <form method="POST" action="{:U('SpTransferproduct/changeStatus')}" id="formSubmit" class="form1">
        <div class="text-center" style="margin-top:20px;">
            <input type="hidden" name="dataId" value="{:$dataId}"/>
            <eq name='transferStatus' value='0'>
                <label class="radio-inline">
                    <input type="radio" name='status' value="10" checked> 审核通过
                </label>
                <label class="radio-inline">
                    <input type="radio" name='status' value="20"> 拒绝请求
                </label><br/><br/>
            </eq>
            <in name="transferStatus" value="0">
                <button type='button' class='btn btn-primary ajax-post' target-form="form1"
                        onclick="return confirmIt()">审 核
                </button>
            </in>

        </div>
        </form>
    </div>
    <div class="page">
        {$_page}
    </div>
</block>

<block name="script">
    <script src="__STATIC__/thinkbox/jquery.thinkbox.js"></script>

    <script type="text/javascript">
        //搜索查询
        $('#submit').click(function () {
            document.getElementById("form-search").submit()
        });
        function confirmIt() {
            $("#formSubmit").submit();
        }
        //导航高亮
        highlight_subnav('{:U('SpTransferproduct/index')}');
    </script>
</block>